﻿<%--
  Created by IntelliJ IDEA.
  User: 王旭东
  Date: 2025/5/13
  Time: 21:55
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" isELIgnored="false" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<html>
<head>
    <title>教务管理系统登录</title>
    <link href="${pageContext.request.contextPath}/resources/css/login.css" rel="stylesheet">

</head>
<body>

<%-- 可选的背景漂浮物动画 --%>
<div class="floating-shapes">
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
    <div></div>
</div>

<div class="login-container">
    <h2>教务管理系统</h2>
    <form action="${pageContext.request.contextPath}/user/login" method="post">
        <div class="form-group">
            <label for="username">用户名:</label>
            <input type="text" id="username" name="username" required placeholder="请输入用户名">
        </div>
        <div class="form-group">
            <label for="password">密码:</label>
            <input type="password" id="password" name="password" required placeholder="请输入密码">
        </div>
        <div class="form-group">
            <label for="role">角色:</label>
            <select id="role" name="role" required>
                <option value="">请选择角色</option>
                <option value="1">管理员</option>
                <option value="2">教师</option>
                <option value="3">学生</option>
            </select>
        </div>
        <div>
            <button type="submit" class="login-button">登录</button>
        </div>
        <c:if test="${not empty error}">
            <p class="error-message">${error}</p>
        </c:if>
    </form>
</div>

</body>
</html>

